<!--分享名片组件-->
<template>
    <div class="card">
        <van-popup v-model="show" :close-on-click-overlay="false">
            <div class="businessCard">
                <div class="top">
                    <p class="sendTxt">发送给</p>
                    <div class="targetInfo">
                        <img src="../assets/img/messageAvatar.png">
                        <p>爱萝莉真是太好了</p>
                    </div>
                    <p class="source">[个人名片]念旧</p>
                    <input type="text" placeholder="给朋友留言">
                </div>
                <div class="bot">
                    <div class="cancle" @click="calcle">取消</div>
                    <div class="send" @click="sendCard">发送</div>
                </div>
            </div>
        </van-popup>
    </div>
</template>

<script>
    import {Popup} from 'vant';

    export default {
        data() {
            return {}
        },
        components: {
            [Popup.name]: Popup
        },
        methods: {
            calcle() {
                this.$emit("cancel")
            },
            sendCard() {
                this.$emit("sendCard");
            }
        },
        props: ["show"]
    }
</script>

<style scoped lang="less">

    .van-popup {
        background-color: transparent;
    }

    .businessCard {
        width: 640px;
        height: 530px;
        background: rgba(255, 255, 255, 1);
        border-radius: 10px;

        .top {
            width: 100%;
            padding: 46px 40px 0 40px;
            box-sizing: border-box;

            .sendTxt {
                font-size: 32px;
                font-family: PingFangSC-Medium;
                font-weight: 500;
                color: rgba(50, 50, 50, 1);
                margin-bottom: 24px;
            }

            .targetInfo {
                display: flex;
                align-items: center;
                width: 100%;
                padding-bottom: 30px;
                box-sizing: border-box;
                border-bottom: 1px solid #F2F5F8;

                img {
                    width: 80px;
                    height: 80px;
                    border-radius: 5px;
                    margin-right: 21px;
                }

                p {
                    font-size: 28px;
                    font-family: PingFangSC-Regular;
                    font-weight: 400;
                    color: rgba(50, 50, 50, 1);
                }
            }

            .source {
                margin: 30px 0 50px 0;
                font-size: 28px;
                font-family: PingFangSC-Regular;
                font-weight: 400;
                color: rgba(153, 153, 153, 1);
            }

            input {
                vertical-align: top;
                width: 100%;
                height: 80px;
                background: #fff;
                border: 2px solid rgba(214, 215, 220, 1);
                border-radius: 10px;
                padding-left: 31px;
                box-sizing: border-box;
                outline: none;
                -webkit-appearance: none;
                font-size: 28px;

                &::-webkit-input-placeholder {
                    font-size: 30px;
                    font-family: PingFangSC-Regular;
                    font-weight: 400;
                    color: rgba(153, 153, 153, 1);
                }

                &:-ms-input-placeholder {
                    font-size: 30px;
                    font-family: PingFangSC-Regular;
                    font-weight: 400;
                    color: rgba(153, 153, 153, 1);
                }
            }
        }

        .bot {
            display: flex;
            position: absolute;
            width: 100%;
            height: 87px;
            border-top: 1px solid #DFE0E2;
            left: 0;
            bottom: 0;

            div {
                width: 50%;
                height: 100%;
                font-size: 34px;
                font-family: PingFangSC-Regular;
                font-weight: 400;
                color: rgba(153, 153, 153, 1);
                text-align: center;
                line-height: 87px;
            }

            .cancle {
                border-right: 1px solid #DFE0E2;
            }

            .send {
                color: #627df1;
            }
        }

    }

</style>
